//
//  UITextField+additions.m
//  Tool
//
//  Created by ZJ on 17/2/15.
//  Copyright © 2017年 ZJ. All rights reserved.
//

#import "UITextField+additions.h"

@implementation UITextField (additions)

- (void)setTextFieldLeftforWidth:(CGFloat)leftWidth
{
    CGRect frame = self.frame;
    frame.size.width = leftWidth;
    UIView *leftview = [[UIView alloc] initWithFrame:frame];
    self.leftViewMode = UITextFieldViewModeAlways;
    self.leftView = leftview;
}
- (void)setTextFieldRightforWidth:(CGFloat)RightWidth

{
    CGRect frame = self.frame;
    frame.size.width = RightWidth;
    UIView *rightView = [[UIView alloc] initWithFrame:frame];
    self.rightViewMode = UITextFieldViewModeAlways;
    self.rightView = rightView;
}

@end
